package com.zzyl.task;

import com.xxl.job.core.handler.annotation.XxlJob;
import com.zzyl.mapper.ReservationMapper;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;
import java.time.LocalDateTime;

@Component
public class XxlJobTask {


    @Resource
    ReservationMapper reservationMapper;

    @XxlJob("firstJob")
    public void exec() {
        int i = reservationMapper.autoUpdateStatus(LocalDateTime.now());
        System.out.println("xiugai完成"+i);
    }
}
